fix(ci): apt-get update before apt install in docker-image jobs#4011
Merged
Conversation
The randomized-tests and frameworks jobs run on the docker:29.4.0-noble image and apt-install php/git/make/curl at runtime, but without refreshing the apt index first. The image's baked index goes stale and breaks once Ubuntu's security pocket supersedes a pinned package (currently libxml2), e.g.: Err … libxml2 2.9.14+dfsg-1.3ubuntu3.7 404 Not Found E: Failed to fetch … maybe run apt-get update Add 'apt-get update' before each of the three 'apt install' steps in generate-package.php (the other apt jobs in this file already do this).
apt-get update before apt install in docker-image jobs
|
Leiyks
approved these changes
Jun 24, 2026
Collaborator
|
Alternatively, we could just have rebuilt these images, but okay :-D |
Member
Author
|
We have an aging todo in there to build a proper image that has php, make and git pre-installed: dd-trace-php/.gitlab/generate-package.php Line 792 in 8b0c1e6 The image used here is "just" an ubuntu iamge. I figured it'll be a little less bad than it is currently with adding |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
While working on #4002 all
randomized testsjob suddenly started failing. This is because of the apt index is stale on the image and we are not updating it before runningapt install -y php git make curl, so that fails with:This also fails on
mastersince today: https://gitlab.ddbuild.io/DataDog/apm-reliability/dd-trace-php/-/jobs/1799170178This PR adds
apt-get updatebefore each of the threeapt installsteps in.gitlab/generate-package.php. The other apt-based jobs in this file already do this.Reviewer checklist